﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace SLControlLibrary.Demo
{
    public partial class ExtendedCalendar : UserControl
    {
        public ExtendedCalendar()
        {
            InitializeComponent();
        }

        private void UserControl_Loaded(object sender, RoutedEventArgs e)
        {
            TextBlock tb = new TextBlock();
            tb.Text = "<SLCalendar:ucCalendar x:Name=\"ccDisplay\"" + Environment.NewLine +
                      "MonthHeight=\"160\"" + Environment.NewLine +
                      "MonthWidth=\"185\"" + Environment.NewLine +
                      "MonthSpan=\"3\"" + Environment.NewLine +
                      "BorderThickness=\"1\"" + Environment.NewLine +
                      "VerticalAlignment=\"Top\" />";

            TabItem ti = (TabItem)tcDisplay.Items[1];
            ti.Content = tb;

            TextBlock tb2 = new TextBlock();
            tb2.Text = "ucCalendar Calendar = new ucCalendar();" + Environment.NewLine +
            "Calendar.MonthHeight = 160;" + Environment.NewLine +
            "Calendar.MonthWidth = 185;" + Environment.NewLine +
            "Calendar.MonthSpan = 3;" + Environment.NewLine +
            "Calendar.BorderThickness = new Thickness(1);" + Environment.NewLine +
            "Calendar.VerticalAlignment = VerticalAlignment.Top;";

            TabItem ti2 = (TabItem)tcDisplay.Items[2];
            ti2.Content = tb2;
        }
    }
}
